<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>flex大小</title>
    <style>
        .box {
            display: flex;
            height: 300px;
            border: 1px solid #000;
        }

        .one {
            flex: 1;
            width: 200px;
            background-color: gray;
        }

        .two {
            background-color: red;
            flex: 2;
        }

        .three {
            background-color: yellow;
            flex: 1;
        }
    </style>
</head>

<body>
    <div class="box">
        <div class="one">1</div>
        <div class="two">2</div>
        <div class="three">3</div>
    </div>
</body>

</html>